home *** CD-ROM | disk | FTP | other *** search
/ Libris Britannia 4 / science library(b).zip / science library(b) / DJGPP / BCCGRX12.ZIP / contrib / bcc2grx / src / bccgrx08.c < prev    next >
C/C++ Source or Header  |  1993-05-03  |  821b  |  33 lines

  1. /*
  2.  *  BCC2GRX  -  Interfacing Borland based graphics programs to LIBGRX
  3.  *  Copyright (C) 1993  Hartmut Schirmer
  4.  *
  5.  *  see bccgrx.c for details
  6.  */
  7.  
  8. #include "bccgrx00.h"
  9.  
  10. /* ----------------------------------------------------------------- */
  11. void setfillstyle(int pattern, int color)
  12. {
  13.   _DO_INIT_CHECK;
  14.   if (pattern < 0 || pattern >= USER_FILL) {
  15.     ERR = grError;
  16.     return;
  17.   }
  18.   FPATT = pattern;
  19.   FILL  = color;
  20.   FILLP.gp_bmp_data = (unsigned char *)&__gr_fpatterns[FPATT];
  21. }
  22.  
  23. /* ----------------------------------------------------------------- */
  24. void setfillpattern( char  *upattern, int color)
  25. {
  26.   _DO_INIT_CHECK;
  27.   FILL  = color;
  28.   FPATT = USER_FILL;
  29.   memcpy(__gr_fpatterns[USER_FILL], upattern, 8);
  30.   FILLP.gp_bmp_data = (unsigned char *)&__gr_fpatterns[USER_FILL];
  31. }
  32.  
  33.